#include <iostream>
#include "bitmap.h"
#include "mycontrols.h"

using namespace std;

int main(void)
{ form *formular = new form(10,1,60,20,"Formular");
  panel *panel1 = new panel(1,1,25,10,"Panel1");
  formular->add_control(panel1);
  radiobutton *tlacitkorb1 = new radiobutton(1,1,20,1,"Radiobutton 1");
  panel1->add_control(tlacitkorb1);
  radiobutton *tlacitkorb2 = new radiobutton(1,3,20,1,"Radiobutton 2");
  panel1->add_control(tlacitkorb2);
  radiobutton *tlacitkorb3 = new radiobutton(1,5,20,1,"Radiobutton 3");
  panel1->add_control(tlacitkorb3);
  tlacitkorb1->set_checked(true);
  tlacitkorb3->set_checked(true);
  tlacitkorb2->set_checked(true);
  panel *panel2 = new panel(30,1,25,10,"Panel2");
  formular->add_control(panel2);
  checkbox *tlacitkochb1 = new checkbox(1,1,20,1,"Checkbox 1");
  panel2->add_control(tlacitkochb1);
  tlacitkochb1->set_checked(true);
  checkbox *tlacitkochb2 = new checkbox(1,3,20,1,"Checkbox 2");
  panel2->add_control(tlacitkochb2);
  tlacitkochb2->set_checked(true);
  checkbox *tlacitkochb3 = new checkbox(1,5,20,1,"Checkbox 3");
  panel2->add_control(tlacitkochb3);
  tlacitkochb3->set_checked(true);
  tlacitkochb2->set_checked(false);
  button *tlacitko1 = new button(1,12,10,3,"OK");
  formular->add_control(tlacitko1);
  button *tlacitko2 = new button(30,12,11,3,"Err");
  formular->add_control(tlacitko2);
  bitmap b(79,24);
  formular->paint(&b);
  b.draw(&cout);
  delete formular;
  return 0;
}

